package index.Btree;

public interface BtreeNodeInterface {
	
	
	// |---ҳ��----|---Ԫ����----|----����ָ��------|----Ҷ��---|--����   ��--|--Ҷ�ڵ��ǰһ������ҳ��--|--����--||([ָ��/ҳ��][���])([ָ��/ҳ��][���])([ָ��/ҳ��][���])....(Ԫ�ظ���)||
	// |-------------------ҳͷ-----------------------------------------------||([ָ��/ҳ��][���])([ָ��/ҳ��][���])([ָ��/ҳ��][���])....(Ԫ�ظ���)||
	// |-------------ҳ(�ڵ�)�ṹ---------------------------------------------------------------------------------------------------------------------------||

	public static final int k_n = 4 ; // ÿ���ڵ��Ԫ�ظ���(k)
	
	public static final int k_leaf = 3072 ; // һ���ڵ�/ҳ �ж����ֽ�
	
	public static final int k_leaf_head = 72 ; // �ڵ�/ҳ ͷ�����ֽ�
	
	public static final int k_leaf_num = 4 ; // �ڵ�/ҳ Ԫ����������ֽ�
	
	public static final int k_leaf_pagenum = 4 ;// �ڵ�/ҳ Ԫ������ҳ���ֽ���
	
	public static final int k_leaf_numpointer = 2 ; //  �ڵ�/ҳ Ԫ�ص�ƫ����
	
	public static final int k_leaf_head_num = 4 ;//  �ڵ�/ҳ  ͷ�������ҳ��
	
	public static final int k_leaf_head_count = 4 ; // �ڵ�/ҳ  ͷ����Ԫ�ظ���
	
	public static final int k_leaf_head_rightson = 4 ; // �ڵ�/ҳ  ͷ������洢�� ��ҳ����ָ��
	
	public static final int k_leaf_head_orleaf = 4 ; //�Ƿ���Ҷ�ӽڵ� (1-yes,0-no);
	
	public static final int k_leaf_head_parent = 4; //���ڵ���ռ�Ĵ�С
	
	public static final int k_leaf_head_brother=4;//ǰһ�����
	
	public abstract int getTag();   //���ҳ��
	
	public abstract int getNum();   //���Ԫ�������
	
	public abstract int getRighson();  //�������ָ�� 
	
	public abstract int getOrleaf(); //��ȡ�Ƿ�ΪҶ�ӽڵ�
		
	public abstract int getKey(int i);      //��ȡ���(��i��)
	
	public abstract int[] getkey();    //��ȡ�������
	 	
	public abstract int getPageNum(int i); //��ȡ��Ԫָ�루ҳ�ţ�
	
	public abstract int[] getPageNum();    //��ȡ��Ԫָ�루ҳ�ţ�����
	
	public abstract int getParent();  //��ȡ���ڵ�
	
	public abstract int getBrother();//Ҷ�ӽڵ��ȡǰһ���ڵ�
	
	public abstract void getNode(int tag); //һ�λ�ȡһ���ڵ�������ֽ�
	
	public abstract void setTag(int i);   //����ҳ��
	
	public abstract void setNum(int i);   //����Ԫ����
	
	public abstract void setRighson(int i);  //��������ָ�� 
	
	public abstract void setOrleaf(int i); //�����Ƿ�ΪҶ�ӽڵ�
	
	public abstract void setKey(int i,int l);      //�������(iΪλ��, l Ϊֵ)
	
	public abstract void setKey(int[] i);      //�����������
	
	public abstract void setPageNum(int i,int l);    //���õ�Ԫָ�루ҳ�ţ�(iΪλ��, l Ϊֵ)
	
	public abstract void setPageNum(int[] i);    //���õ�Ԫָ�루ҳ�ţ�	
	
	public abstract void setParent(int i); //���ø��ڵ�
	
	public abstract void setBrother(int i);//����ǰһ�����ҳ��
	
	public abstract void setNode(int num,int rightson,int orleaf,int parent,int brother,int[] key,int[] pagenum); //ͳһ���ýڵ�
}
